import{S as qa,i as Ja,s as Aa,e as s,k as h,w,t,M as Wa,c as r,d as n,m as f,a as i,x as T,h as a,b as d,G as e,g as _,y as k,q as L,o as $,B as O,v as Ua,L as Ia}from"../../chunks/vendor-hf-doc-builder.js";import{T as Io}from"../../chunks/Tip-hf-doc-builder.js";import{D as Ne}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Sa}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as ro}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as xa}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function Na(E){let l,b,c,u,v,p,g,y;return{c(){l=s("p"),b=t("This model is in maintenance mode only, so we won\u2019t accept any new PRs changing its code."),c=h(),u=s("p"),v=t(`If you run into any issues running this model, please reinstall the last version that supported this model: v4.31.0.
You can do so by running the following command: `),p=s("code"),g=t("pip install -U transformers==4.31.0"),y=t(".")},l(M){l=r(M,"P",{});var C=i(l);b=a(C,"This model is in maintenance mode only, so we won\u2019t accept any new PRs changing its code."),C.forEach(n),c=f(M),u=r(M,"P",{});var F=i(u);v=a(F,`If you run into any issues running this model, please reinstall the last version that supported this model: v4.31.0.
You can do so by running the following command: `),p=r(F,"CODE",{});var A=i(p);g=a(A,"pip install -U transformers==4.31.0"),A.forEach(n),y=a(F,"."),F.forEach(n)},m(M,C){_(M,l,C),e(l,b),_(M,c,C),_(M,u,C),e(u,v),e(u,p),e(p,g),e(u,y)},d(M){M&&n(l),M&&n(c),M&&n(u)}}}function Ba(E){let l,b,c,u,v,p,g,y;return{c(){l=s("p"),b=t("This model differs from the "),c=s("a"),u=t("OpenLLaMA models"),v=t(" on the Hugging Face Hub, which primarily use the "),p=s("a"),g=t("LLaMA"),y=t(" architecture."),this.h()},l(M){l=r(M,"P",{});var C=i(l);b=a(C,"This model differs from the "),c=r(C,"A",{href:!0,rel:!0});var F=i(c);u=a(F,"OpenLLaMA models"),F.forEach(n),v=a(C," on the Hugging Face Hub, which primarily use the "),p=r(C,"A",{href:!0});var A=i(p);g=a(A,"LLaMA"),A.forEach(n),y=a(C," architecture."),C.forEach(n),this.h()},h(){d(c,"href","https://huggingface.co/models?search=openllama"),d(c,"rel","nofollow"),d(p,"href","llama")},m(M,C){_(M,l,C),e(l,b),e(l,c),e(c,u),e(l,v),e(l,p),e(p,g),e(l,y)},d(M){M&&n(l)}}}function Va(E){let l,b;return l=new Sa({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyME9wZW5MbGFtYU1vZGVsJTJDJTIwT3BlbkxsYW1hQ29uZmlnJTBBJTBBJTIzJTIwSW5pdGlhbGl6aW5nJTIwYSUyME9wZW4tTGxhbWElMjBvcGVuX2xsYW1hLTdiJTIwc3R5bGUlMjBjb25maWd1cmF0aW9uJTBBY29uZmlndXJhdGlvbiUyMCUzRCUyME9wZW5MbGFtYUNvbmZpZygpJTBBJTBBJTIzJTIwSW5pdGlhbGl6aW5nJTIwYSUyMG1vZGVsJTIwZnJvbSUyMHRoZSUyMG9wZW5fbGxhbWEtN2IlMjBzdHlsZSUyMGNvbmZpZ3VyYXRpb24lMEFtb2RlbCUyMCUzRCUyME9wZW5MbGFtYU1vZGVsKGNvbmZpZ3VyYXRpb24pJTBBJTBBJTIzJTIwQWNjZXNzaW5nJTIwdGhlJTIwbW9kZWwlMjBjb25maWd1cmF0aW9uJTBBY29uZmlndXJhdGlvbiUyMCUzRCUyMG1vZGVsLmNvbmZpZw==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> OpenLlamaModel, OpenLlamaConfig

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a Open-Llama open_llama-7b style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = OpenLlamaConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model from the open_llama-7b style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = OpenLlamaModel(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(){w(l.$$.fragment)},l(c){T(l.$$.fragment,c)},m(c,u){k(l,c,u),b=!0},p:Ia,i(c){b||(L(l.$$.fragment,c),b=!0)},o(c){$(l.$$.fragment,c),b=!1},d(c){O(l,c)}}}function ja(E){let l,b,c,u,v;return{c(){l=s("p"),b=t("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s("code"),u=t("Module"),v=t(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(p){l=r(p,"P",{});var g=i(l);b=a(g,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=r(g,"CODE",{});var y=i(c);u=a(y,"Module"),y.forEach(n),v=a(g,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),g.forEach(n)},m(p,g){_(p,l,g),e(l,b),e(l,c),e(c,u),e(l,v)},d(p){p&&n(l)}}}function Da(E){let l,b,c,u,v;return{c(){l=s("p"),b=t("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s("code"),u=t("Module"),v=t(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(p){l=r(p,"P",{});var g=i(l);b=a(g,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=r(g,"CODE",{});var y=i(c);u=a(y,"Module"),y.forEach(n),v=a(g,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),g.forEach(n)},m(p,g){_(p,l,g),e(l,b),e(l,c),e(c,u),e(l,v)},d(p){p&&n(l)}}}function Ga(E){let l,b,c,u,v;return u=new Sa({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBPcGVuTGxhbWFGb3JDYXVzYWxMTSUwQSUwQW1vZGVsJTIwJTNEJTIwT3BlbkxsYW1hRm9yQ2F1c2FsTE0uZnJvbV9wcmV0cmFpbmVkKFBBVEhfVE9fQ09OVkVSVEVEX1dFSUdIVFMpJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQoUEFUSF9UT19DT05WRVJURURfVE9LRU5JWkVSKSUwQSUwQXByb21wdCUyMCUzRCUyMCUyMkhleSUyQyUyMGFyZSUyMHlvdSUyMGNvbnNjaW91cyUzRiUyMENhbiUyMHlvdSUyMHRhbGslMjB0byUyMG1lJTNGJTIyJTBBaW5wdXRzJTIwJTNEJTIwdG9rZW5pemVyKHByb21wdCUyQyUyMHJldHVybl90ZW5zb3JzJTNEJTIycHQlMjIpJTBBJTBBJTIzJTIwR2VuZXJhdGUlMEFnZW5lcmF0ZV9pZHMlMjAlM0QlMjBtb2RlbC5nZW5lcmF0ZShpbnB1dHMuaW5wdXRfaWRzJTJDJTIwbWF4X2xlbmd0aCUzRDMwKSUwQXRva2VuaXplci5iYXRjaF9kZWNvZGUoZ2VuZXJhdGVfaWRzJTJDJTIwc2tpcF9zcGVjaWFsX3Rva2VucyUzRFRydWUlMkMlMjBjbGVhbl91cF90b2tlbml6YXRpb25fc3BhY2VzJTNERmFsc2UpJTVCMCU1RA==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, OpenLlamaForCausalLM

<span class="hljs-meta">&gt;&gt;&gt; </span>model = OpenLlamaForCausalLM.from_pretrained(PATH_TO_CONVERTED_WEIGHTS)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(PATH_TO_CONVERTED_TOKENIZER)

<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;Hey, are you conscious? Can you talk to me?&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(prompt, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Generate</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>generate_ids = model.generate(inputs.input_ids, max_length=<span class="hljs-number">30</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.batch_decode(generate_ids, skip_special_tokens=<span class="hljs-literal">True</span>, clean_up_tokenization_spaces=<span class="hljs-literal">False</span>)[<span class="hljs-number">0</span>]
<span class="hljs-string">&quot;Hey, are you conscious? Can you talk to me?\\nI&#x27;m not conscious, but I can talk to you.&quot;</span>`}}),{c(){l=s("p"),b=t("Example:"),c=h(),w(u.$$.fragment)},l(p){l=r(p,"P",{});var g=i(l);b=a(g,"Example:"),g.forEach(n),c=f(p),T(u.$$.fragment,p)},m(p,g){_(p,l,g),e(l,b),_(p,c,g),k(u,p,g),v=!0},p:Ia,i(p){v||(L(u.$$.fragment,p),v=!0)},o(p){$(u.$$.fragment,p),v=!1},d(p){p&&n(l),p&&n(c),O(u,p)}}}function Za(E){let l,b,c,u,v;return{c(){l=s("p"),b=t("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s("code"),u=t("Module"),v=t(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(p){l=r(p,"P",{});var g=i(l);b=a(g,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=r(g,"CODE",{});var y=i(c);u=a(y,"Module"),y.forEach(n),v=a(g,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),g.forEach(n)},m(p,g){_(p,l,g),e(l,b),e(l,c),e(c,u),e(l,v)},d(p){p&&n(l)}}}function Ra(E){let l,b,c,u,v,p,g,y,M,C,F,A,ee,So,V,oe,io,ge,an,lo,sn,qo,ne,rn,_e,ln,dn,Jo,Be,cn,Ao,q,pn,be,mn,hn,ve,fn,un,ye,gn,_n,Wo,j,te,co,we,bn,po,vn,Uo,I,Te,yn,D,wn,Ve,Tn,kn,ke,Ln,$n,On,G,Mn,je,Cn,zn,De,En,Fn,Pn,ae,No,Z,se,mo,Le,xn,ho,In,Bo,P,$e,Sn,Oe,qn,Ge,Jn,An,Wn,Me,Un,Ce,Nn,Bn,Vn,re,jn,fo,Dn,Gn,uo,Zn,Rn,W,ze,Hn,R,Xn,Ze,Yn,Qn,go,Kn,et,ot,ie,Vo,H,le,_o,Ee,nt,bo,tt,jo,X,Fe,at,J,Pe,st,Y,rt,Re,it,lt,vo,dt,ct,pt,de,mt,ce,Do,Q,pe,yo,xe,ht,wo,ft,Go,z,Ie,ut,To,gt,_t,He,Xe,bt,vt,yt,S,wt,ko,Tt,kt,Lo,Lt,$t,$o,Ot,Mt,Oo,Ct,zt,Et,Se,Ft,Ye,Pt,xt,It,qe,St,Je,qt,Jt,At,U,Ae,Wt,K,Ut,Qe,Nt,Bt,Mo,Vt,jt,Dt,me,Zo;return p=new ro({}),F=new Io({props:{warning:!0,$$slots:{default:[Na]},$$scope:{ctx:E}}}),ee=new Io({props:{warning:!0,$$slots:{default:[Ba]},$$scope:{ctx:E}}}),ge=new ro({}),we=new ro({}),Te=new Ne({props:{name:"class transformers.OpenLlamaConfig",anchor:"transformers.OpenLlamaConfig",parameters:[{name:"vocab_size",val:" = 100000"},{name:"hidden_size",val:" = 4096"},{name:"intermediate_size",val:" = 11008"},{name:"num_hidden_layers",val:" = 32"},{name:"num_attention_heads",val:" = 32"},{name:"hidden_act",val:" = 'silu'"},{name:"max_position_embeddings",val:" = 2048"},{name:"initializer_range",val:" = 0.02"},{name:"rms_norm_eps",val:" = 1e-06"},{name:"use_cache",val:" = True"},{name:"pad_token_id",val:" = 0"},{name:"bos_token_id",val:" = 1"},{name:"eos_token_id",val:" = 2"},{name:"tie_word_embeddings",val:" = False"},{name:"use_memory_efficient_attention",val:" = True"},{name:"hidden_dropout_prob",val:" = 0.1"},{name:"attention_dropout_prob",val:" = 0.1"},{name:"use_stable_embedding",val:" = True"},{name:"shared_input_output_embedding",val:" = True"},{name:"rope_scaling",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.OpenLlamaConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 32000) &#x2014;
Vocabulary size of the Open-Llama model. Defines the number of different tokens that can be represented by
the <code>inputs_ids</code> passed when calling <a href="/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaModel">OpenLlamaModel</a>`,name:"vocab_size"},{anchor:"transformers.OpenLlamaConfig.hidden_size",description:`<strong>hidden_size</strong> (<code>int</code>, <em>optional</em>, defaults to 4096) &#x2014;
Dimension of the hidden representations.`,name:"hidden_size"},{anchor:"transformers.OpenLlamaConfig.intermediate_size",description:`<strong>intermediate_size</strong> (<code>int</code>, <em>optional</em>, defaults to 11008) &#x2014;
Dimension of the MLP representations.`,name:"intermediate_size"},{anchor:"transformers.OpenLlamaConfig.num_hidden_layers",description:`<strong>num_hidden_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 32) &#x2014;
Number of hidden layers in the Transformer encoder.`,name:"num_hidden_layers"},{anchor:"transformers.OpenLlamaConfig.num_attention_heads",description:`<strong>num_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 32) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"num_attention_heads"},{anchor:"transformers.OpenLlamaConfig.hidden_act",description:`<strong>hidden_act</strong> (<code>str</code> or <code>function</code>, <em>optional</em>, defaults to <code>&quot;silu&quot;</code>) &#x2014;
The non-linear activation function (function or string) in the decoder.`,name:"hidden_act"},{anchor:"transformers.OpenLlamaConfig.max_position_embeddings",description:`<strong>max_position_embeddings</strong> (<code>int</code>, <em>optional</em>, defaults to 2048) &#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.OpenLlamaConfig.initializer_range",description:`<strong>initializer_range</strong> (<code>float</code>, <em>optional</em>, defaults to 0.02) &#x2014;
The standard deviation of the truncated_normal_initializer for initializing all weight matrices.`,name:"initializer_range"},{anchor:"transformers.OpenLlamaConfig.rms_norm_eps",description:`<strong>rms_norm_eps</strong> (<code>float</code>, <em>optional</em>, defaults to 1e-12) &#x2014;
The epsilon used by the rms normalization layers.`,name:"rms_norm_eps"},{anchor:"transformers.OpenLlamaConfig.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not the model should return the last key/values attentions (not used by all models). Only
relevant if <code>config.is_decoder=True</code>.`,name:"use_cache"},{anchor:"transformers.OpenLlamaConfig.tie_word_embeddings(bool,",description:`<strong>tie_word_embeddings(<code>bool</code>,</strong> <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to tie weight embeddings`,name:"tie_word_embeddings(bool,"},{anchor:"transformers.OpenLlamaConfig.rope_scaling",description:`<strong>rope_scaling</strong> (<code>Dict</code>, <em>optional</em>) &#x2014;
Dictionary containing the scaling configuration for the RoPE embeddings. Currently supports two scaling
strategies: linear and dynamic. Their scaling factor must be an float greater than 1. The expected format
is <code>{&quot;type&quot;: strategy name, &quot;factor&quot;: scaling factor}</code>. When using this flag, don&#x2019;t update
<code>max_position_embeddings</code> to the expected new maximum. See the following thread for more information on how
these scaling strategies behave:
<a href="https://www.reddit.com/r/LocalLLaMA/comments/14mrgpr/dynamically_scaled_rope_further_increases/" rel="nofollow">https://www.reddit.com/r/LocalLLaMA/comments/14mrgpr/dynamically_scaled_rope_further_increases/</a>. This is an
experimental feature, subject to breaking API changes in future versions.</p>
<p>Example &#x2014;`,name:"rope_scaling"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/configuration_open_llama.py#L33"}}),ae=new xa({props:{anchor:"transformers.OpenLlamaConfig.example",$$slots:{default:[Va]},$$scope:{ctx:E}}}),Le=new ro({}),$e=new Ne({props:{name:"class transformers.OpenLlamaModel",anchor:"transformers.OpenLlamaModel",parameters:[{name:"config",val:": OpenLlamaConfig"}],parametersDescription:[{anchor:"transformers.OpenLlamaModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaConfig">OpenLlamaConfig</a>) &#x2014;
Model configuration class with all the parameters of the model. Initializing with a config file does not
load the weights associated with the model, only the configuration. Check out the
<a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.
config &#x2014; OpenLlamaConfig`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/modeling_open_llama.py#L529"}}),ze=new Ne({props:{name:"forward",anchor:"transformers.OpenLlamaModel.forward",parameters:[{name:"input_ids",val:": LongTensor = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[torch.FloatTensor]] = None"},{name:"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.OpenLlamaModel.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/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.OpenLlamaModel.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></p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p>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>).</p>
<p>If you want to change padding behavior, you should read <code>modeling_opt._prepare_decoder_attention_mask</code>
and 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.</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:"attention_mask"},{anchor:"transformers.OpenLlamaModel.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.n_positions - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.OpenLlamaModel.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>.`,name:"past_key_values"},{anchor:"transformers.OpenLlamaModel.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.OpenLlamaModel.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.OpenLlamaModel.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.OpenLlamaModel.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.OpenLlamaModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/modeling_open_llama.py#L584"}}),ie=new Io({props:{$$slots:{default:[ja]},$$scope:{ctx:E}}}),Ee=new ro({}),Fe=new Ne({props:{name:"class transformers.OpenLlamaForCausalLM",anchor:"transformers.OpenLlamaForCausalLM",parameters:[{name:"config",val:""}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/modeling_open_llama.py#L717"}}),Pe=new Ne({props:{name:"forward",anchor:"transformers.OpenLlamaForCausalLM.forward",parameters:[{name:"input_ids",val:": LongTensor = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = 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.OpenLlamaForCausalLM.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/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.OpenLlamaForCausalLM.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></p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p>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>).</p>
<p>If you want to change padding behavior, you should read <code>modeling_opt._prepare_decoder_attention_mask</code>
and 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.</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:"attention_mask"},{anchor:"transformers.OpenLlamaForCausalLM.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.n_positions - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.OpenLlamaForCausalLM.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>.`,name:"past_key_values"},{anchor:"transformers.OpenLlamaForCausalLM.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.OpenLlamaForCausalLM.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.OpenLlamaForCausalLM.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.OpenLlamaForCausalLM.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.OpenLlamaForCausalLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.</p>
<p>Args &#x2014;
labels (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>):
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:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/modeling_open_llama.py#L747",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.CausalLMOutputWithPast"
>transformers.modeling_outputs.CausalLMOutputWithPast</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaConfig"
>OpenLlamaConfig</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>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>)</p>
<p>Contains pre-computed hidden-states (key and values in the self-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(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.CausalLMOutputWithPast"
>transformers.modeling_outputs.CausalLMOutputWithPast</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),de=new Io({props:{$$slots:{default:[Da]},$$scope:{ctx:E}}}),ce=new xa({props:{anchor:"transformers.OpenLlamaForCausalLM.forward.example",$$slots:{default:[Ga]},$$scope:{ctx:E}}}),xe=new ro({}),Ie=new Ne({props:{name:"class transformers.OpenLlamaForSequenceClassification",anchor:"transformers.OpenLlamaForSequenceClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.OpenLlamaForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaConfig">OpenLlamaConfig</a>) &#x2014;
Model configuration class with all the parameters of the model. Initializing with a config file does not
load the weights associated with the model, only the configuration. Check out the
<a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/modeling_open_llama.py#L896"}}),Ae=new Ne({props:{name:"forward",anchor:"transformers.OpenLlamaForSequenceClassification.forward",parameters:[{name:"input_ids",val:": LongTensor = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = 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.OpenLlamaForSequenceClassification.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/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.OpenLlamaForSequenceClassification.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></p>
<p>Indices can be obtained using <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/main/en/internal/tokenization_utils#transformers.PreTrainedTokenizerBase.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p>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>).</p>
<p>If you want to change padding behavior, you should read <code>modeling_opt._prepare_decoder_attention_mask</code>
and 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.</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:"attention_mask"},{anchor:"transformers.OpenLlamaForSequenceClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.n_positions - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.OpenLlamaForSequenceClassification.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>.`,name:"past_key_values"},{anchor:"transformers.OpenLlamaForSequenceClassification.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.OpenLlamaForSequenceClassification.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.OpenLlamaForSequenceClassification.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.OpenLlamaForSequenceClassification.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.OpenLlamaForSequenceClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.OpenLlamaForSequenceClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/deprecated/open_llama/modeling_open_llama.py#L912"}}),me=new Io({props:{$$slots:{default:[Za]},$$scope:{ctx:E}}}),{c(){l=s("meta"),b=h(),c=s("h1"),u=s("a"),v=s("span"),w(p.$$.fragment),g=h(),y=s("span"),M=t("Open-Llama"),C=h(),w(F.$$.fragment),A=h(),w(ee.$$.fragment),So=h(),V=s("h2"),oe=s("a"),io=s("span"),w(ge.$$.fragment),an=h(),lo=s("span"),sn=t("Overview"),qo=h(),ne=s("p"),rn=t("The Open-Llama model was proposed in "),_e=s("a"),ln=t("Open-Llama project"),dn=t(" by community developer s-JoL."),Jo=h(),Be=s("p"),cn=t(`The model is mainly based on LLaMA with some modifications, incorporating memory-efficient attention from Xformers, stable embedding from Bloom, and shared input-output embedding from PaLM.
And the model is pre-trained on both Chinese and English, which gives it better performance on Chinese language tasks.`),Ao=h(),q=s("p"),pn=t("This model was contributed by "),be=s("a"),mn=t("s-JoL"),hn=t(`.
The original code can be found `),ve=s("a"),fn=t("Open-Llama"),un=t(`.
Checkpoint and usage can be found at `),ye=s("a"),gn=t("s-JoL/Open-Llama-V1"),_n=t("."),Wo=h(),j=s("h2"),te=s("a"),co=s("span"),w(we.$$.fragment),bn=h(),po=s("span"),vn=t("OpenLlamaConfig"),Uo=h(),I=s("div"),w(Te.$$.fragment),yn=h(),D=s("p"),wn=t("This is the configuration class to store the configuration of a "),Ve=s("a"),Tn=t("OpenLlamaModel"),kn=t(`. It is used to instantiate an
Open-Llama 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
`),ke=s("a"),Ln=t("s-JoL/Open-Llama-V1"),$n=t("."),On=h(),G=s("p"),Mn=t("Configuration objects inherit from "),je=s("a"),Cn=t("PretrainedConfig"),zn=t(` and can be used to control the model outputs. Read the
documentation from `),De=s("a"),En=t("PretrainedConfig"),Fn=t(" for more information."),Pn=h(),w(ae.$$.fragment),No=h(),Z=s("h2"),se=s("a"),mo=s("span"),w(Le.$$.fragment),xn=h(),ho=s("span"),In=t("OpenLlamaModel"),Bo=h(),P=s("div"),w($e.$$.fragment),Sn=h(),Oe=s("p"),qn=t(`The bare Open-Llama Model outputting raw hidden-states without any specific head on top.
This model inherits from `),Ge=s("a"),Jn=t("PreTrainedModel"),An=t(`. 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.)`),Wn=h(),Me=s("p"),Un=t("This model is also a PyTorch "),Ce=s("a"),Nn=t("torch.nn.Module"),Bn=t(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Vn=h(),re=s("p"),jn=t("Transformer decoder consisting of "),fo=s("em"),Dn=t("config.num_hidden_layers"),Gn=t(" layers. Each layer is a "),uo=s("code"),Zn=t("OpenLlamaDecoderLayer"),Rn=h(),W=s("div"),w(ze.$$.fragment),Hn=h(),R=s("p"),Xn=t("The "),Ze=s("a"),Yn=t("OpenLlamaModel"),Qn=t(" forward method, overrides the "),go=s("code"),Kn=t("__call__"),et=t(" special method."),ot=h(),w(ie.$$.fragment),Vo=h(),H=s("h2"),le=s("a"),_o=s("span"),w(Ee.$$.fragment),nt=h(),bo=s("span"),tt=t("OpenLlamaForCausalLM"),jo=h(),X=s("div"),w(Fe.$$.fragment),at=h(),J=s("div"),w(Pe.$$.fragment),st=h(),Y=s("p"),rt=t("The "),Re=s("a"),it=t("OpenLlamaForCausalLM"),lt=t(" forward method, overrides the "),vo=s("code"),dt=t("__call__"),ct=t(" special method."),pt=h(),w(de.$$.fragment),mt=h(),w(ce.$$.fragment),Do=h(),Q=s("h2"),pe=s("a"),yo=s("span"),w(xe.$$.fragment),ht=h(),wo=s("span"),ft=t("OpenLlamaForSequenceClassification"),Go=h(),z=s("div"),w(Ie.$$.fragment),ut=h(),To=s("p"),gt=t("The LLaMa Model transformer with a sequence classification head on top (linear layer)."),_t=h(),He=s("p"),Xe=s("a"),bt=t("OpenLlamaForSequenceClassification"),vt=t(` uses the last token in order to do the classification, as other causal
models (e.g. GPT-2) do.`),yt=h(),S=s("p"),wt=t(`Since it does classification on the last token, it requires to know the position of the last token. If a
`),ko=s("code"),Tt=t("pad_token_id"),kt=t(` is defined in the configuration, it finds the last token that is not a padding token in each row. If
no `),Lo=s("code"),Lt=t("pad_token_id"),$t=t(` is defined, it simply takes the last value in each row of the batch. Since it cannot guess the
padding tokens when `),$o=s("code"),Ot=t("inputs_embeds"),Mt=t(" are passed instead of "),Oo=s("code"),Ct=t("input_ids"),zt=t(`, it does the same (take the last value in
each row of the batch).`),Et=h(),Se=s("p"),Ft=t("This model inherits from "),Ye=s("a"),Pt=t("PreTrainedModel"),xt=t(`. 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.)`),It=h(),qe=s("p"),St=t("This model is also a PyTorch "),Je=s("a"),qt=t("torch.nn.Module"),Jt=t(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),At=h(),U=s("div"),w(Ae.$$.fragment),Wt=h(),K=s("p"),Ut=t("The "),Qe=s("a"),Nt=t("OpenLlamaForSequenceClassification"),Bt=t(" forward method, overrides the "),Mo=s("code"),Vt=t("__call__"),jt=t(" special method."),Dt=h(),w(me.$$.fragment),this.h()},l(o){const m=Wa('[data-svelte="svelte-1phssyn"]',document.head);l=r(m,"META",{name:!0,content:!0}),m.forEach(n),b=f(o),c=r(o,"H1",{class:!0});var We=i(c);u=r(We,"A",{id:!0,class:!0,href:!0});var Co=i(u);v=r(Co,"SPAN",{});var zo=i(v);T(p.$$.fragment,zo),zo.forEach(n),Co.forEach(n),g=f(We),y=r(We,"SPAN",{});var Eo=i(y);M=a(Eo,"Open-Llama"),Eo.forEach(n),We.forEach(n),C=f(o),T(F.$$.fragment,o),A=f(o),T(ee.$$.fragment,o),So=f(o),V=r(o,"H2",{class:!0});var Ue=i(V);oe=r(Ue,"A",{id:!0,class:!0,href:!0});var Fo=i(oe);io=r(Fo,"SPAN",{});var Po=i(io);T(ge.$$.fragment,Po),Po.forEach(n),Fo.forEach(n),an=f(Ue),lo=r(Ue,"SPAN",{});var Zt=i(lo);sn=a(Zt,"Overview"),Zt.forEach(n),Ue.forEach(n),qo=f(o),ne=r(o,"P",{});var Ro=i(ne);rn=a(Ro,"The Open-Llama model was proposed in "),_e=r(Ro,"A",{href:!0,rel:!0});var Rt=i(_e);ln=a(Rt,"Open-Llama project"),Rt.forEach(n),dn=a(Ro," by community developer s-JoL."),Ro.forEach(n),Jo=f(o),Be=r(o,"P",{});var Ht=i(Be);cn=a(Ht,`The model is mainly based on LLaMA with some modifications, incorporating memory-efficient attention from Xformers, stable embedding from Bloom, and shared input-output embedding from PaLM.
And the model is pre-trained on both Chinese and English, which gives it better performance on Chinese language tasks.`),Ht.forEach(n),Ao=f(o),q=r(o,"P",{});var he=i(q);pn=a(he,"This model was contributed by "),be=r(he,"A",{href:!0,rel:!0});var Xt=i(be);mn=a(Xt,"s-JoL"),Xt.forEach(n),hn=a(he,`.
The original code can be found `),ve=r(he,"A",{href:!0,rel:!0});var Yt=i(ve);fn=a(Yt,"Open-Llama"),Yt.forEach(n),un=a(he,`.
Checkpoint and usage can be found at `),ye=r(he,"A",{href:!0,rel:!0});var Qt=i(ye);gn=a(Qt,"s-JoL/Open-Llama-V1"),Qt.forEach(n),_n=a(he,"."),he.forEach(n),Wo=f(o),j=r(o,"H2",{class:!0});var Ho=i(j);te=r(Ho,"A",{id:!0,class:!0,href:!0});var Kt=i(te);co=r(Kt,"SPAN",{});var ea=i(co);T(we.$$.fragment,ea),ea.forEach(n),Kt.forEach(n),bn=f(Ho),po=r(Ho,"SPAN",{});var oa=i(po);vn=a(oa,"OpenLlamaConfig"),oa.forEach(n),Ho.forEach(n),Uo=f(o),I=r(o,"DIV",{class:!0});var fe=i(I);T(Te.$$.fragment,fe),yn=f(fe),D=r(fe,"P",{});var Ke=i(D);wn=a(Ke,"This is the configuration class to store the configuration of a "),Ve=r(Ke,"A",{href:!0});var na=i(Ve);Tn=a(na,"OpenLlamaModel"),na.forEach(n),kn=a(Ke,`. It is used to instantiate an
Open-Llama 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
`),ke=r(Ke,"A",{href:!0,rel:!0});var ta=i(ke);Ln=a(ta,"s-JoL/Open-Llama-V1"),ta.forEach(n),$n=a(Ke,"."),Ke.forEach(n),On=f(fe),G=r(fe,"P",{});var eo=i(G);Mn=a(eo,"Configuration objects inherit from "),je=r(eo,"A",{href:!0});var aa=i(je);Cn=a(aa,"PretrainedConfig"),aa.forEach(n),zn=a(eo,` and can be used to control the model outputs. Read the
documentation from `),De=r(eo,"A",{href:!0});var sa=i(De);En=a(sa,"PretrainedConfig"),sa.forEach(n),Fn=a(eo," for more information."),eo.forEach(n),Pn=f(fe),T(ae.$$.fragment,fe),fe.forEach(n),No=f(o),Z=r(o,"H2",{class:!0});var Xo=i(Z);se=r(Xo,"A",{id:!0,class:!0,href:!0});var ra=i(se);mo=r(ra,"SPAN",{});var ia=i(mo);T(Le.$$.fragment,ia),ia.forEach(n),ra.forEach(n),xn=f(Xo),ho=r(Xo,"SPAN",{});var la=i(ho);In=a(la,"OpenLlamaModel"),la.forEach(n),Xo.forEach(n),Bo=f(o),P=r(o,"DIV",{class:!0});var N=i(P);T($e.$$.fragment,N),Sn=f(N),Oe=r(N,"P",{});var Yo=i(Oe);qn=a(Yo,`The bare Open-Llama Model outputting raw hidden-states without any specific head on top.
This model inherits from `),Ge=r(Yo,"A",{href:!0});var da=i(Ge);Jn=a(da,"PreTrainedModel"),da.forEach(n),An=a(Yo,`. 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.)`),Yo.forEach(n),Wn=f(N),Me=r(N,"P",{});var Qo=i(Me);Un=a(Qo,"This model is also a PyTorch "),Ce=r(Qo,"A",{href:!0,rel:!0});var ca=i(Ce);Nn=a(ca,"torch.nn.Module"),ca.forEach(n),Bn=a(Qo,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Qo.forEach(n),Vn=f(N),re=r(N,"P",{});var xo=i(re);jn=a(xo,"Transformer decoder consisting of "),fo=r(xo,"EM",{});var pa=i(fo);Dn=a(pa,"config.num_hidden_layers"),pa.forEach(n),Gn=a(xo," layers. Each layer is a "),uo=r(xo,"CODE",{});var ma=i(uo);Zn=a(ma,"OpenLlamaDecoderLayer"),ma.forEach(n),xo.forEach(n),Rn=f(N),W=r(N,"DIV",{class:!0});var oo=i(W);T(ze.$$.fragment,oo),Hn=f(oo),R=r(oo,"P",{});var no=i(R);Xn=a(no,"The "),Ze=r(no,"A",{href:!0});var ha=i(Ze);Yn=a(ha,"OpenLlamaModel"),ha.forEach(n),Qn=a(no," forward method, overrides the "),go=r(no,"CODE",{});var fa=i(go);Kn=a(fa,"__call__"),fa.forEach(n),et=a(no," special method."),no.forEach(n),ot=f(oo),T(ie.$$.fragment,oo),oo.forEach(n),N.forEach(n),Vo=f(o),H=r(o,"H2",{class:!0});var Ko=i(H);le=r(Ko,"A",{id:!0,class:!0,href:!0});var ua=i(le);_o=r(ua,"SPAN",{});var ga=i(_o);T(Ee.$$.fragment,ga),ga.forEach(n),ua.forEach(n),nt=f(Ko),bo=r(Ko,"SPAN",{});var _a=i(bo);tt=a(_a,"OpenLlamaForCausalLM"),_a.forEach(n),Ko.forEach(n),jo=f(o),X=r(o,"DIV",{class:!0});var en=i(X);T(Fe.$$.fragment,en),at=f(en),J=r(en,"DIV",{class:!0});var ue=i(J);T(Pe.$$.fragment,ue),st=f(ue),Y=r(ue,"P",{});var to=i(Y);rt=a(to,"The "),Re=r(to,"A",{href:!0});var ba=i(Re);it=a(ba,"OpenLlamaForCausalLM"),ba.forEach(n),lt=a(to," forward method, overrides the "),vo=r(to,"CODE",{});var va=i(vo);dt=a(va,"__call__"),va.forEach(n),ct=a(to," special method."),to.forEach(n),pt=f(ue),T(de.$$.fragment,ue),mt=f(ue),T(ce.$$.fragment,ue),ue.forEach(n),en.forEach(n),Do=f(o),Q=r(o,"H2",{class:!0});var on=i(Q);pe=r(on,"A",{id:!0,class:!0,href:!0});var ya=i(pe);yo=r(ya,"SPAN",{});var wa=i(yo);T(xe.$$.fragment,wa),wa.forEach(n),ya.forEach(n),ht=f(on),wo=r(on,"SPAN",{});var Ta=i(wo);ft=a(Ta,"OpenLlamaForSequenceClassification"),Ta.forEach(n),on.forEach(n),Go=f(o),z=r(o,"DIV",{class:!0});var x=i(z);T(Ie.$$.fragment,x),ut=f(x),To=r(x,"P",{});var ka=i(To);gt=a(ka,"The LLaMa Model transformer with a sequence classification head on top (linear layer)."),ka.forEach(n),_t=f(x),He=r(x,"P",{});var Gt=i(He);Xe=r(Gt,"A",{href:!0});var La=i(Xe);bt=a(La,"OpenLlamaForSequenceClassification"),La.forEach(n),vt=a(Gt,` uses the last token in order to do the classification, as other causal
models (e.g. GPT-2) do.`),Gt.forEach(n),yt=f(x),S=r(x,"P",{});var B=i(S);wt=a(B,`Since it does classification on the last token, it requires to know the position of the last token. If a
`),ko=r(B,"CODE",{});var $a=i(ko);Tt=a($a,"pad_token_id"),$a.forEach(n),kt=a(B,` is defined in the configuration, it finds the last token that is not a padding token in each row. If
no `),Lo=r(B,"CODE",{});var Oa=i(Lo);Lt=a(Oa,"pad_token_id"),Oa.forEach(n),$t=a(B,` is defined, it simply takes the last value in each row of the batch. Since it cannot guess the
padding tokens when `),$o=r(B,"CODE",{});var Ma=i($o);Ot=a(Ma,"inputs_embeds"),Ma.forEach(n),Mt=a(B," are passed instead of "),Oo=r(B,"CODE",{});var Ca=i(Oo);Ct=a(Ca,"input_ids"),Ca.forEach(n),zt=a(B,`, it does the same (take the last value in
each row of the batch).`),B.forEach(n),Et=f(x),Se=r(x,"P",{});var nn=i(Se);Ft=a(nn,"This model inherits from "),Ye=r(nn,"A",{href:!0});var za=i(Ye);Pt=a(za,"PreTrainedModel"),za.forEach(n),xt=a(nn,`. 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.)`),nn.forEach(n),It=f(x),qe=r(x,"P",{});var tn=i(qe);St=a(tn,"This model is also a PyTorch "),Je=r(tn,"A",{href:!0,rel:!0});var Ea=i(Je);qt=a(Ea,"torch.nn.Module"),Ea.forEach(n),Jt=a(tn,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),tn.forEach(n),At=f(x),U=r(x,"DIV",{class:!0});var ao=i(U);T(Ae.$$.fragment,ao),Wt=f(ao),K=r(ao,"P",{});var so=i(K);Ut=a(so,"The "),Qe=r(so,"A",{href:!0});var Fa=i(Qe);Nt=a(Fa,"OpenLlamaForSequenceClassification"),Fa.forEach(n),Bt=a(so," forward method, overrides the "),Mo=r(so,"CODE",{});var Pa=i(Mo);Vt=a(Pa,"__call__"),Pa.forEach(n),jt=a(so," special method."),so.forEach(n),Dt=f(ao),T(me.$$.fragment,ao),ao.forEach(n),x.forEach(n),this.h()},h(){d(l,"name","hf:doc:metadata"),d(l,"content",JSON.stringify(Ha)),d(u,"id","openllama"),d(u,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),d(u,"href","#openllama"),d(c,"class","relative group"),d(oe,"id","overview"),d(oe,"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"),d(oe,"href","#overview"),d(V,"class","relative group"),d(_e,"href","https://github.com/s-JoL/Open-Llama"),d(_e,"rel","nofollow"),d(be,"href","https://huggingface.co/s-JoL"),d(be,"rel","nofollow"),d(ve,"href","https://github.com/s-JoL/Open-Llama"),d(ve,"rel","nofollow"),d(ye,"href","https://huggingface.co/s-JoL/Open-Llama-V1"),d(ye,"rel","nofollow"),d(te,"id","transformers.OpenLlamaConfig"),d(te,"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"),d(te,"href","#transformers.OpenLlamaConfig"),d(j,"class","relative group"),d(Ve,"href","/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaModel"),d(ke,"href","https://huggingface.co/s-JoL/Open-Llama-V1"),d(ke,"rel","nofollow"),d(je,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),d(De,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),d(I,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),d(se,"id","transformers.OpenLlamaModel"),d(se,"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"),d(se,"href","#transformers.OpenLlamaModel"),d(Z,"class","relative group"),d(Ge,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),d(Ce,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),d(Ce,"rel","nofollow"),d(Ze,"href","/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaModel"),d(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),d(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),d(le,"id","transformers.OpenLlamaForCausalLM"),d(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"),d(le,"href","#transformers.OpenLlamaForCausalLM"),d(H,"class","relative group"),d(Re,"href","/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaForCausalLM"),d(J,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),d(X,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),d(pe,"id","transformers.OpenLlamaForSequenceClassification"),d(pe,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),d(pe,"href","#transformers.OpenLlamaForSequenceClassification"),d(Q,"class","relative group"),d(Xe,"href","/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaForSequenceClassification"),d(Ye,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),d(Je,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),d(Je,"rel","nofollow"),d(Qe,"href","/docs/transformers/main/en/model_doc/open-llama#transformers.OpenLlamaForSequenceClassification"),d(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),d(z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(o,m){e(document.head,l),_(o,b,m),_(o,c,m),e(c,u),e(u,v),k(p,v,null),e(c,g),e(c,y),e(y,M),_(o,C,m),k(F,o,m),_(o,A,m),k(ee,o,m),_(o,So,m),_(o,V,m),e(V,oe),e(oe,io),k(ge,io,null),e(V,an),e(V,lo),e(lo,sn),_(o,qo,m),_(o,ne,m),e(ne,rn),e(ne,_e),e(_e,ln),e(ne,dn),_(o,Jo,m),_(o,Be,m),e(Be,cn),_(o,Ao,m),_(o,q,m),e(q,pn),e(q,be),e(be,mn),e(q,hn),e(q,ve),e(ve,fn),e(q,un),e(q,ye),e(ye,gn),e(q,_n),_(o,Wo,m),_(o,j,m),e(j,te),e(te,co),k(we,co,null),e(j,bn),e(j,po),e(po,vn),_(o,Uo,m),_(o,I,m),k(Te,I,null),e(I,yn),e(I,D),e(D,wn),e(D,Ve),e(Ve,Tn),e(D,kn),e(D,ke),e(ke,Ln),e(D,$n),e(I,On),e(I,G),e(G,Mn),e(G,je),e(je,Cn),e(G,zn),e(G,De),e(De,En),e(G,Fn),e(I,Pn),k(ae,I,null),_(o,No,m),_(o,Z,m),e(Z,se),e(se,mo),k(Le,mo,null),e(Z,xn),e(Z,ho),e(ho,In),_(o,Bo,m),_(o,P,m),k($e,P,null),e(P,Sn),e(P,Oe),e(Oe,qn),e(Oe,Ge),e(Ge,Jn),e(Oe,An),e(P,Wn),e(P,Me),e(Me,Un),e(Me,Ce),e(Ce,Nn),e(Me,Bn),e(P,Vn),e(P,re),e(re,jn),e(re,fo),e(fo,Dn),e(re,Gn),e(re,uo),e(uo,Zn),e(P,Rn),e(P,W),k(ze,W,null),e(W,Hn),e(W,R),e(R,Xn),e(R,Ze),e(Ze,Yn),e(R,Qn),e(R,go),e(go,Kn),e(R,et),e(W,ot),k(ie,W,null),_(o,Vo,m),_(o,H,m),e(H,le),e(le,_o),k(Ee,_o,null),e(H,nt),e(H,bo),e(bo,tt),_(o,jo,m),_(o,X,m),k(Fe,X,null),e(X,at),e(X,J),k(Pe,J,null),e(J,st),e(J,Y),e(Y,rt),e(Y,Re),e(Re,it),e(Y,lt),e(Y,vo),e(vo,dt),e(Y,ct),e(J,pt),k(de,J,null),e(J,mt),k(ce,J,null),_(o,Do,m),_(o,Q,m),e(Q,pe),e(pe,yo),k(xe,yo,null),e(Q,ht),e(Q,wo),e(wo,ft),_(o,Go,m),_(o,z,m),k(Ie,z,null),e(z,ut),e(z,To),e(To,gt),e(z,_t),e(z,He),e(He,Xe),e(Xe,bt),e(He,vt),e(z,yt),e(z,S),e(S,wt),e(S,ko),e(ko,Tt),e(S,kt),e(S,Lo),e(Lo,Lt),e(S,$t),e(S,$o),e($o,Ot),e(S,Mt),e(S,Oo),e(Oo,Ct),e(S,zt),e(z,Et),e(z,Se),e(Se,Ft),e(Se,Ye),e(Ye,Pt),e(Se,xt),e(z,It),e(z,qe),e(qe,St),e(qe,Je),e(Je,qt),e(qe,Jt),e(z,At),e(z,U),k(Ae,U,null),e(U,Wt),e(U,K),e(K,Ut),e(K,Qe),e(Qe,Nt),e(K,Bt),e(K,Mo),e(Mo,Vt),e(K,jt),e(U,Dt),k(me,U,null),Zo=!0},p(o,[m]){const We={};m&2&&(We.$$scope={dirty:m,ctx:o}),F.$set(We);const Co={};m&2&&(Co.$$scope={dirty:m,ctx:o}),ee.$set(Co);const zo={};m&2&&(zo.$$scope={dirty:m,ctx:o}),ae.$set(zo);const Eo={};m&2&&(Eo.$$scope={dirty:m,ctx:o}),ie.$set(Eo);const Ue={};m&2&&(Ue.$$scope={dirty:m,ctx:o}),de.$set(Ue);const Fo={};m&2&&(Fo.$$scope={dirty:m,ctx:o}),ce.$set(Fo);const Po={};m&2&&(Po.$$scope={dirty:m,ctx:o}),me.$set(Po)},i(o){Zo||(L(p.$$.fragment,o),L(F.$$.fragment,o),L(ee.$$.fragment,o),L(ge.$$.fragment,o),L(we.$$.fragment,o),L(Te.$$.fragment,o),L(ae.$$.fragment,o),L(Le.$$.fragment,o),L($e.$$.fragment,o),L(ze.$$.fragment,o),L(ie.$$.fragment,o),L(Ee.$$.fragment,o),L(Fe.$$.fragment,o),L(Pe.$$.fragment,o),L(de.$$.fragment,o),L(ce.$$.fragment,o),L(xe.$$.fragment,o),L(Ie.$$.fragment,o),L(Ae.$$.fragment,o),L(me.$$.fragment,o),Zo=!0)},o(o){$(p.$$.fragment,o),$(F.$$.fragment,o),$(ee.$$.fragment,o),$(ge.$$.fragment,o),$(we.$$.fragment,o),$(Te.$$.fragment,o),$(ae.$$.fragment,o),$(Le.$$.fragment,o),$($e.$$.fragment,o),$(ze.$$.fragment,o),$(ie.$$.fragment,o),$(Ee.$$.fragment,o),$(Fe.$$.fragment,o),$(Pe.$$.fragment,o),$(de.$$.fragment,o),$(ce.$$.fragment,o),$(xe.$$.fragment,o),$(Ie.$$.fragment,o),$(Ae.$$.fragment,o),$(me.$$.fragment,o),Zo=!1},d(o){n(l),o&&n(b),o&&n(c),O(p),o&&n(C),O(F,o),o&&n(A),O(ee,o),o&&n(So),o&&n(V),O(ge),o&&n(qo),o&&n(ne),o&&n(Jo),o&&n(Be),o&&n(Ao),o&&n(q),o&&n(Wo),o&&n(j),O(we),o&&n(Uo),o&&n(I),O(Te),O(ae),o&&n(No),o&&n(Z),O(Le),o&&n(Bo),o&&n(P),O($e),O(ze),O(ie),o&&n(Vo),o&&n(H),O(Ee),o&&n(jo),o&&n(X),O(Fe),O(Pe),O(de),O(ce),o&&n(Do),o&&n(Q),O(xe),o&&n(Go),o&&n(z),O(Ie),O(Ae),O(me)}}}const Ha={local:"openllama",sections:[{local:"overview",title:"Overview"},{local:"transformers.OpenLlamaConfig",title:"OpenLlamaConfig"},{local:"transformers.OpenLlamaModel",title:"OpenLlamaModel"},{local:"transformers.OpenLlamaForCausalLM",title:"OpenLlamaForCausalLM"},{local:"transformers.OpenLlamaForSequenceClassification",title:"OpenLlamaForSequenceClassification"}],title:"Open-Llama"};function Xa(E){return Ua(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class ts extends qa{constructor(l){super();Ja(this,l,Xa,Ra,Aa,{})}}export{ts as default,Ha as metadata};
